package com.oop.demo06;

public class Student extends Person{
    private String name = "lihua";
    public void test(String name){
        System.out.println(name);
        System.out.println(this.name);
        System.out.println(super.name);
    }
    public void test1(){
        print();
        this.print();
        super.print();

    }

    public Student() {
        //默认会先去调用父类的无参构造
        super();//就是这句代码
        System.out.println("student无参构造器执行了");
    }

    public void print(){
        System.out.println("student");
    }
}
